import 'package:flutter_test/flutter_test.dart';
import 'package:multi_image_picker_plus/multi_image_picker_plus.dart';
import 'package:multi_image_picker_plus/multi_image_picker_plus_platform_interface.dart';
import 'package:multi_image_picker_plus/multi_image_picker_plus_method_channel.dart';
import 'package:plugin_platform_interface/plugin_platform_interface.dart';

class MockMultiImagePickerPlusPlatform
    with MockPlatformInterfaceMixin
    implements MultiImagePickerPlusPlatform {

  @override
  Future<String?> getPlatformVersion() => Future.value('42');
}

void main() {
  final MultiImagePickerPlusPlatform initialPlatform = MultiImagePickerPlusPlatform.instance;

  test('$MethodChannelMultiImagePickerPlus is the default instance', () {
    expect(initialPlatform, isInstanceOf<MethodChannelMultiImagePickerPlus>());
  });

  test('getPlatformVersion', () async {
    MultiImagePickerPlus multiImagePickerPlusPlugin = MultiImagePickerPlus();
    MockMultiImagePickerPlusPlatform fakePlatform = MockMultiImagePickerPlusPlatform();
    MultiImagePickerPlusPlatform.instance = fakePlatform;

    expect(await multiImagePickerPlusPlugin.getPlatformVersion(), '42');
  });
}
